import Http from '@/utils/http';
// 请求参数详情可以看 https://nuxt.com/docs/api/composables/use-fetch#params
// Options 这个参数可以设置其他的属性，比如传 {server: false} 那就是此接口不需要在服务端调用，默认调用的。

export const config1 = (params?: any, Options?: any) => {
  return Http.get('/common/set', params, Options)
}

export const config2 = (params?: any) => {
  return Http.get('/common/get', params)
}

export const handleLogin = (params?: any) => {
  return new Promise((resolve, reject) => {
    Http.post('/user/login', params).then((res) => {
      console.log("res login", res);
      resolve(res);
    })
  })
}